/**
 * Created with BlueStream
 * Date: 13. 6. 1
 * Time: 오후 11:43
 * Writer: 강석민
 */
window.onload = function () {
    var m_1 = document.getElementById("m_1");
    m_1.style.color = "red";

    var m_2 = document.getElementById("m_2");
    m_2.className = "active";

    var m_3 = document.getElementById("m_3");
    var img = m_3.getElementsByTagName("img")[0];
    img.src = "./img/ch3.png";

    var m_4 = document.getElementById("m_4");
    m_4.innerHTML = m_4.innerHTML+"<p>항목4</p>";

    var m_5 = document.getElementById("m_5");
    var m_5Childs = m_5.getElementsByTagName("p")
    var i;
    var len;
    i = 0;
    len = m_5Childs.length;
    while(i<len){
        var m_5Child = m_5Childs[i];
        if(m_5Child.innerText == "항목4"){
            m_5.removeChild(m_5Child);
            break;
        }
        ++i;
    }

    var m_6 = document.getElementById("m_6");
    var m_6_parent = m_6.parentNode;
    document.body.removeChild(m_6_parent);

}